﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Entity;
using Controller;
namespace Web
{
    public partial class VendorList : System.Web.UI.Page
    {
        IList<VendorEntity> vendorEntities = new List<VendorEntity>();
        VendorController vendorController = new VendorController();
        protected void Page_Load(object sender, EventArgs e)
        {
            vendorEntities = vendorController.FindAllVendorEntities();
            this.VendorGridView.DataSource = vendorEntities;
            this.VendorGridView.DataBind();
        }

        protected void AddButton_Click(object sender, EventArgs e)
        {
            Response.Redirect("~/CreateVendor.aspx");
        }
    }
}